// CommandLineHelper Library
// =========================
// License: Microsoft Permissive License (Ms-PL) v1.1
// Author: Rhy Mednick (http://www.rhyverse.net)
// Project Site: http://www.codeplex.com/CommandLineHelper
using System;
using System.Collections.Generic;
using System.Text;
using NUnit.Framework;
using CommandLineHelper.Attributes;

namespace CommandLineHelper.Tests
{
    [TestFixture]
    public class ValidateNotNullAttribute_Test
    {
        /// <summary>
        ///A test for IsValid (object)
        ///</summary>
        [Test]
        public void IsValid_ValidateNotNullAttribute()
        {
            ValidateNotNullAttribute target = new ValidateNotNullAttribute();

            object value = null;
            bool expected = false;
            bool actual = target.IsValid(value);
            Assert.AreEqual(expected, actual, "CommandLineHelper.Attributes.ValidateNotNullAttribute.IsValid did not return the expected value.");

            value = (object)new String('x', 10);
            expected = true;
            actual = target.IsValid(value);
            Assert.AreEqual(expected, actual, "CommandLineHelper.Attributes.ValidateNotNullAttribute.IsValid did not return the expected value.");

        }
    }
}
